package cn.assumejson.springframework.aop;

import cn.assumejson.springframework.aop.aspectj.TrueClassFilter;

/**
 * 匹配class
 *
 * @author Mr. Li
 * @version 1.0
 * @since 1.0 2021/12/2 13:19
 */
@FunctionalInterface
public interface ClassFilter {
    /**
     * Should the pointcut apply to the given interface or target class?
     *
     * @param clazz the candidate target class
     * @return whether the advice should apply to the given target class
     */
    boolean matches(Class<?> clazz);

    ClassFilter TRUE = TrueClassFilter.INSTANCE;

}
